Imports System
Imports System.Text
Imports System.Collections.Generic
Imports Microsoft.Practices.EnterpriseLibrary.Configuration.Design

''' <summary>
''' Intercepts creation of the ExceptionTypeDesignNode
''' </summary>
Class AddApplicationBlockSettingsNodeCommand
	Inherits AddChildNodeCommand

    Private serviceProvider As IServiceProvider

	''' <summary>
    ''' Initialize a new instance of the <see cref="AddApplicationBlockSettingsNodeCommand"/> class with an <see cref="IServiceProvider"/>.
	''' </summary>
	''' <param name="serviceProvider">The a mechanism for retrieving a service object that is, an object that provides custom support to other objects.</param>
    Public Sub New(ByVal myServiceProvider As IServiceProvider)
        MyBase.New(myServiceProvider, GetType(ApplicationBlockSettingsNode))
        serviceProvider = myServiceProvider
    End Sub

	''' <summary>
    ''' Adds the default nodes.
	''' </summary>
    ''' <param name="node">The <see cref="ApplicationBlockSettingsNode"/> added.</param>
	Protected Overrides Sub ExecuteCore(ByVal node As ConfigurationNode)
		MyBase.ExecuteCore(node)
		Dim blockSettingsNode As ApplicationBlockSettingsNode = CType(ChildNode, ApplicationBlockSettingsNode)
		If blockSettingsNode Is Nothing Then
			Return
		End If

		' TODO: Initialize your initial configuration settings for the $Name$ Design-Time.
	End Sub
End Class